package com.huanong.it.xwweibo.authority.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.huanong.it.xwweibo.authority.domain.Role;
import com.huanong.it.xwweibo.authority.mapper.RoleMapper;
import com.huanong.it.xwweibo.authority.service.RoleService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author Limhuang
* @description 针对表【sys_role】的数据库操作Service实现
* @createDate 2024-06-23 22:12:37
*/
@Service
public class RoleServiceImpl extends ServiceImpl<RoleMapper, Role>
    implements RoleService {


    @Override
    public List<Role> getRoleByRoleCode(List<String> codes) {
        QueryWrapper<Role> queryWrapper = new QueryWrapper<>();
        queryWrapper.lambda().in(Role::getCode, codes);
        return baseMapper.selectList(queryWrapper);
    }
}




